﻿using System;
using System.ComponentModel;

namespace UploadClient.View
{
    /// <summary>
    /// Object for the star-icon.
    /// </summary>
    public class Favourite : INotifyPropertyChanged
    {
        private bool isFavourite;

        public Favourite(bool value)
        {
            this.isFavourite = value;
        }

        public bool IsFavourite
        {
            get { return isFavourite; }
            set
            {
                isFavourite = value;
                NotifyPropertyChanged("IsFavourite");
            }
        }

        #region INotifyPropertyChanged Members

        public event PropertyChangedEventHandler PropertyChanged;

        #endregion

        private void NotifyPropertyChanged(String info)
        {
            if (PropertyChanged != null)
            {
                PropertyChanged(this, new PropertyChangedEventArgs(info));
            }
        }
    }
}
